home *** CD-ROM | disk | FTP | other *** search
- /* Prefs.h
- * Interface to routines for preferences file management
- * ©1992 Working Software, Inc.
- * This source code is copyrighted. Permission is granted to use the Word Services
- * portion of the Writeswell Jr. source code in your own programs, but you
- * may not distribute the Writeswell Jr. word-processor code as a
- * commercial product. If you modify the code, please do not call it
- * Writeswell Jr. (or Writeswell.) This will ensure that people understand the
- * program and don’t have to deal with a number of different versions with
- * who-knows-what going on in the code.
- *
- * Writeswell Jr. and Writeswell are trademarks of Working Software, Inc.
- * 18 Apr 92 Mike Crawford
- */
-
- typedef struct {
- short checkSel;
- short sendByList;
- short serviceType[ kMaxServices ];
- } WWJrPrefs, **WWJrPrefsHdl;
-
- typedef enum {
- kNoService = 0,
- kBatchService,
- kInteractiveService
- } ServiceType;
-
- #define kServiceBaseID 1000
- #define kMenuIconBaseID 257
-
- #define kAFPrefsID 128
- #define kPFPrefsID 1128
-
- Boolean OpenPrefFile( void );
- OSErr ValidatePrefsFile( void );
- OSErr GetPrefFolder( short *vRefPtr, long *dirIDPtr );
- Boolean FileExistsWithThisType( short vRef, long dirID, StringPtr fileName, OSType type );
- Boolean CreateDefaultPrefFile( short vRef, long dirID, StringPtr fileName );
- OSErr CopyResource( short fromID,
- short toID,
- ResType theType,
- short fromFile,
- short toFile );
- void ToggleSelectCheck( void );
- MenuHandle GetServiceMenu( void );
- WWJrPrefsHdl GetPrefHandle( void );
- void CheckSelectMenu( WWJrPrefsHdl prefHdl );
-
- /* These functions pre-install Spellswell 7 in the menu, if it is in the same folder */
-
- OSErr AddSpellerItem( void );
- OSErr LookForSpeller( FSSpec *spellSpecPtr, Boolean *foundPtr );
- OSErr PointAliasAtSpeller( short aliasID, const FSSpecPtr spellerSpecPtr );
- OSErr GetMyFolder( short *vRefPtr, long *dirIDPtr );
-